<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<script type="text/javascript">
			//命名函数
			function fn1() {

			}

			//函数表达式
			const fn2 = function() {

			}

			// 构造函数
			function Student(name, age) {
				this.name = name;
				this.age = age;
			}

			// 方法
			const stu = {
				name: "张三",
				age: 20,
				study: function() {
					console.log("学习");
				}
			}


			function fn3(a, b) {
				return a + b;
			}

			//箭头函数(简写)
			const fn4 = (a, b) => a + b;

			console.log(fn4(1, 2));
		</script>
	</head>
	<body>
	</body>
</html>
